<%@page contentType="text/html;charset=UTF-8"%>
<%@page pageEncoding="UTF-8"%>
<%@page import="java.util.*,com.wing.sys.domain.Module" %>
<%@ include file="/pub/includ.jsp"%>
<%
	Integer ismenu = (Integer)request.getAttribute("ismenu");
	Integer linkType = (Integer)request.getAttribute("linkType");
	Integer ispub = (Integer)request.getAttribute("ispub");
%>
<script type="text/javascript">
		var save = function(){
			var flag = "failure";
			var options = {
				type: 'POST',
				async: false,
				dataType: 'content-type',
				success: function(msg) {
					flag = msg;
				}
			}
			$('#moduleform').ajaxSubmit(options);
			return flag;
		}
</script>
<form id="moduleform" action="<%=path %>/sys/module/save" method="post">
<table><tr><td height="2px"></td></tr></table>
<table align="center" width="70%" border="0" cellpadding="5" cellspacing="1" class="table_nbw">
	<thead class="th_nbw">
	<tr>
		<td colspan="2" align="center"><strong>模块信息</strong></td>
	</tr>
	</thead>
	<tr>
		<td align="right" width="40%" style="background-color:fff;height:25px;">上级模块：</td>
		<td align="left" style="background-color:fff">&nbsp;<input class="textfiled_nbw" type="text" id="pname" readonly="readonly" name="pname" value="${pdata.name}"></td>
	</tr>
	<tr>
		<td align="right" style="background-color:fff;height:25px;">模块名称：</td>
		<td align="left" style="background-color:fff">&nbsp;<input class="textfiled_nbw" type="text" id="name" name="name" value="${data.name}"></td>
	</tr>
	<tr>
		<td align="right" style="background-color:fff;height:25px;">模块简称：</td>
		<td align="left" style="background-color:fff">&nbsp;<input class="textfiled_nbw" type="text" id="short_name" name="short_name" value="${data.short_name}"></td>
	</tr>
	<tr>
		<td align="right" style="background-color:fff;height:25px;">链接：</td>
		<td align="left" style="background-color:fff">&nbsp;<input class="textfiled_nbw" type="text" id="url" name="url" value="${data.url}"></td>
	</tr>
	<tr>
		<td align="right" style="background-color:fff;height:25px;">链接类型：</td>
		<td align="left" style="background-color:fff">&nbsp;
			<input type="radio" value="0" checked="checked" name="link_type" />系统链接&nbsp;&nbsp;
			<input type="radio" value="1" <%if(linkType==1){ %>checked="checked" <%} %>name="link_type" />外部链接
		</td>
	</tr>
	<tr>
		<td align="right" style="background-color:fff;height:25px;">是否为系统菜单：</td>
		<td align="left" style="background-color:fff">&nbsp;
			<input type="radio" value="1" checked="checked" name="ismenu" />是&nbsp;&nbsp;
			<input type="radio" value="0" <%if(ismenu==0){ %>checked="checked" <%} %>name="ismenu" />否
		</td>
	</tr>
	<tr>
		<td align="right" style="background-color:fff;height:25px;">是否为公用菜单：</td>
		<td align="left" style="background-color:fff">&nbsp;
			<input type="radio" value="1" checked="checked" name="ispub" />是&nbsp;&nbsp;
			<input type="radio" value="0" <%if(ispub==0){ %>checked="checked" <%} %>name="ispub" />否
		</td>
	</tr>
	<tr>
		<td align="right" style="background-color:fff;height:25px;">描述：</td>
		<td align="left" style="background-color:fff">&nbsp;<input class="textfiled_nbw" type="text" id="module_describe" name="module_describe" value="${data.module_describe}"></td>
	</tr>
	<tr>
		<td align="right" style="background-color:fff;height:25px;">备注：</td>
		<td align="left" style="background-color:fff">&nbsp;<input class="textfiled_nbw" type="text" id="remarks" name="remarks" value="${data.remarks}"></td>
	</tr>
	<tr>
		<td align="right" style="background-color:fff;height:25px;">排序号：</td>
		<td align="left" style="background-color:fff">&nbsp;<input class="textfiled_nbw" type="text" id="order_num" name="order_num" value="${data.order_num}"></td>
	</tr>
</table>	
<table width="100%"><tr><td align="center">
			<input type=hidden name="id" value="${data.id}" />
			<input type=hidden name="parent_id" value="${data.parent_id}" />
			<input type=hidden name="ptree_id" value="${pdata.tree_id}" />
			<input type=hidden name="tree_id" value="${data.tree_id}" />
			<input type=hidden name="code" value="${data.code}" />
			<input type=hidden name="valid_flag" value="${data.valid_flag}" />
</td></tr></table>
</form>
